export default {
    namespaced: true,
    state: {
        opeType: 'add',
        isShow: false,
        data: {
            name: '',
            addr: '',
            age: '',
            birthday: '',
            sex: ''
        },
    },
    actions: {},
    mutations: {
        setOpeType(state, type) {
            if (type === 'add'){ /*清空原有数据*/
                state.data = {name: '', addr: '', age: '', birthday: '', sex: ''}
            }
            state.opeType = type
        },
        setIsShow(state, isShow) {
            state.isShow = isShow
        },
        setData(state, data) {
            state.data = data
        },
    },
    getters: {}
}
